package com.yang.framework.disruptor;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;


/**
 * 类的功能描述
 *
 * @author 杨 强
 * @package com.yang.framework.disruptor
 * @createTime 2023-09-10 15:17
 */
@RestController
@RequestMapping("/disruptor")
public class DisruptorTestController {

    @Resource
    private PayNoticeEventProducer payNoticeEventProducer1;
    @Resource
    private PayNoticeEventProducerWithTranslator payNoticeProducer2;


    @GetMapping("/test")
    public void test(){
        payNoticeEventProducer1.onData(new PayNoticeEvent("hello1"));
        payNoticeProducer2.onData(new PayNoticeEvent("hello2"));
    }
}
